package cn.y.operation.framework.iconfig.i18n;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.LocaleResolver;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

@Configuration
public class WebMvcConfig implements WebMvcConfigurer {
    /*@Bean
    public LocaleResolver localeResolver() {
        FixedLocaleResolver slr = new FixedLocaleResolver();
        //设置默认区域,
        slr.setDefaultLocale(Locale.US);
        return slr;
    }*/

    @Bean
    public LocaleResolver localeResolver() {
        return new MyLocaleResolver();
    }

}